<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %> 
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>    
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>用户注册</title>
 <link rel="stylesheet" href="<%=request.getContextPath()%>/static/common/plugin/nice-validator/demo/demo.css">
</head>
<body>
<c:if test="${!empty mession }">
<Strong>${mession }</Strong>
</c:if>
<form class="form" data-validator-option="{timely:2, focusCleanup:true}" action="<%=request.getContextPath()%>/TalentServlet?command=register" method=post>
  <div class="form-item">
        <label class="label">Code</label>
        <input type="text" name="code" 
            data-rule="required;username;"
            data-rule-username="[/[\w\d]{4,30}/, 'Please enter 3-12 digits, letters, underscores']"
            data-tip="You can use letters, numbers and periods"
           
        >
    </div>

    <div class="form-item">
        <label class="label">Username</label>
        <input type="text" name="username" 
            data-rule="required;username;"
            data-rule-username="[/[\w\d]{4,30}/, 'Please enter 3-12 digits, letters, underscores']"
            data-tip="You can use letters, numbers and periods"
          
        >
    </div>
    <div class="form-item">
        <label class="label">Password</label>
        <input type="password" name="pwd"
            data-rule="Password: required; length(8~16)"
            data-tip="Please fill in at least eight characters"
             placeholder="${talent.password }"
        >
    </div>
    <div class="form-item">
        <label class="label">Verify Password</label>
        <input type="password" name="pwdAgain" data-rule="Verify Password: required; match(pwd)"  >
    </div>
    <div class="form-item">
        <label class="label">Gender</label>
        <select name="gender" data-rule="required">
            <option value="">select ...</option>
            <option value="1">Male</option>
            <option value="2">Female</option>
            
        </select>
    </div>
      <div class="form-item">
        <label class="label">Age</label>
        <select name="age" data-rule="required;age">
        <option value="">-请选择-</option>
           	<script>
          
           	for (var i = 10; i <= 80; i++) {
				document.write('<option value="' + i + '">' + i + '</option>');
			}
					</script>
            
        </select>
    </div>
    <div class="form-item">
        <label class="label">Email</label>
        <input type="text" name="email" data-rule="required;email"  >
    </div>
    <div class="form-item">
        <label class="label">Phone</label>
        <input type="text" name="phone" data-rule="required;phone" >
    </div>
	<div class="form-item">
        <label class="label">Interest</label>
        <label><input type="checkbox" name="interest" value="sports">sports</label>
		<label><input type="checkbox" name="interest" value="movie">movie</label>
		<label><input type="checkbox" name="interest" value="game">game</label>
		<label><input type="checkbox" name="interest" value="Java">Java</label>
		<label><input type="checkbox" name="interest" value="PHP">PHP</label>
    </div>
	

	<div class="form-item">
        <label><input type="checkbox" id="agree_arguments" data-rule="checked">I agree to the service agreement.</label>
    </div>

    <div class="form-item">
        <button type="submit">Submit</button>
        <button onclick="index()">返回首页</button>
       
    </div>

</form>
<p>${talent.hobby}</p>
<script src="http://dn-nice.qbox.me/libs/jquery/1.x/jquery.min.js"></script>
<script src="<%=request.getContextPath()%>/static/common/plugin/nice-validator/jquery.validator.js?local=en"></script>
<script >
function index(){
	location='<%=request.getContextPath() %>/index.jsp';
}



</script>
</body>
</html>